package messages;

import java.net.UnknownHostException;

public class FileNotif extends Message {
       
        /**
         *      Attributes
         */
        private static final long serialVersionUID = -323131172186505610L;
        private String nameFile;
        private boolean request;
        private boolean accepted;
        private long lengthFile;

       
        /**
         * Constructor
         * @param username
         * @param nameFile
         * @param request
         * @param accepted
         * @throws UnknownHostException
         */
        protected FileNotif(String username, String nameFile, boolean request, boolean accepted, long lengthFile) throws UnknownHostException {
                super(username);
                this.nameFile=nameFile;
                this.request=request;
                this.accepted=accepted;
                this.lengthFile=lengthFile;
        }

       
        /**
         * Retourne l'attribut request
         * @return request
         */
        public boolean getRequest() {
                return request;
        }

       
        /**
         * Retourne l'attribut accepted
         * @return accepted
         */
        public boolean getAccepted() {
                return accepted;
        }

       
        /**
         * Retourne le nom du fichier � envoyer
         * @return name of file
         */
        public String getNameFile() {
                return nameFile;
        }
       
        public long getLengthFile() {
                return lengthFile;
        }
}

